package ControlLayer;
import ModelLayer.*;

/**
 * Write a description of class ControlDVD here.
 * 
 * @author (your name) 
 * @version (a version number or a date)
 */
public class ControlDVD
{
    private static final ControlDVD instance = new ControlDVD();
    private DVDCollection collection=new DVDCollection();

    public ControlDVD()
    {
        collection=ModelLayer.DVDCollection.getInstance();
    }

    public static ControlDVD getInstance()
    {
        return instance;
    }

    // start calling methods from the ModemLayer 
    public void createDVD(String id, String title, String artist, String publicationDate)
    {
        collection.createDVD(id, title, artist, publicationDate);  
    }

    public void updateDVDTitle(String id, String title)
    {
        collection.updateDVDTitle(id,title);
    }

    public void updateDVDArtist(String id, String artist)
    {
        collection.updateDVDArtist(id,artist);
    }

    public void updateDVDPublicationDate(String id, String publicationDate)
    {
        collection.updateDVDPublicationDate(id,publicationDate);
    }

    public void removeDVD(String id)  
    {
        collection.removeDVD(id);
    }

    public void printAllDvd()
    {
        collection.printAllDvds();
    }

    public void readDVD(String id)
    {
        collection.readDVD(id);
    }

    public void addCopiesToDVD(String DVDId, int serialNumber, String purchaseDate, int purchasePrice, String state)   
    {
        collection.addCopiesToDVD(DVDId,serialNumber,purchaseDate,purchasePrice, state);
    }  

    public void getCopiesOfDVD(String DVDTitle)
    {
        collection.getCopiesOfDVDByTitle(DVDTitle);
    }

    public boolean checkCopiesOfDVD(String DVDTitle)
    {
        return collection.checkCopiesOfDVD(DVDTitle);
    }

    public String getCopyStatus(int serialNumber)
    {
        return collection.getCopyStatus(serialNumber);
    }

    public void modifyCopyStatus(int serialNumber, String status)
    {
        collection.modifyCopyStatus(serialNumber, status); 
    }

    // end calling methods from the ModemLayer 

   
}
